/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author chilie1221
 */
import java.util.ArrayList;
import java.util.HashMap;
import java.util.LinkedList;
import java.util.List;
import java.util.Queue;
import java.util.Random;

public class swapping {

    private static int proSize, Time;
    final int[] n = {4, 8, 16, 32};
    final int[] n1 = {1, 2, 3, 4, 5};
    List<HashMap<String, Number>> processList = new ArrayList<HashMap<String, Number>>();
    String a[] = new String[]{"*"};

    public static void main(String[] args) {
    }

    public int Memory_generator() {

        Random r1 = new Random();
        proSize = n[r1.nextInt(n.length)];
        return proSize;
    }

    public int Time_generator() {

        Random r2 = new Random();
        Time = n[r2.nextInt(n1.length)];
        return Time;
    }

    public void Process_generaotr() {

        HashMap<String, Number> pro = new HashMap<String, Number>();
        int Time = Time_generator();
        int EachSize = Time_generator();
        for (int i = 0; i <= 25; i++) {
            pro.put("processName", i);
            pro.put("total_run_time", Time);
            pro.put("run_time", 0);
            pro.put("Each_size", EachSize);
            processList.add(pro);
        }
    }

    public void addToFull() {
        int total_Memory = 100;
        if (total_Memory == 100) {
            while (total_Memory >= 0) {
                for (int j = 0; j < 25; j++) {
                    int processName = processList.get(j).get("processName").intValue();
                    int Each_size = processList.get(j).get("Each_Size").intValue();
                    int n = processName + 65;
                    char c = (char) (n);
                    String name = String.valueOf(c); // A .......T
                    a[j] = name;
                    total_Memory -= Each_size;
                }
            }
        }
    }

    public void First_fit() {
        int current_time = 0;
        int total_time = 0;
        int free_Memory[];
        addToFull();
        for (int k = 1; k <= 60; k++) {
            for (int i = 0; i < a.length; i++) {
                for (int j = 0; j < processList.size(); j++) {
                }
            }
        }

    }
}